﻿#ifndef CAMERASTATUSWIDGET_H
#define CAMERASTATUSWIDGET_H

#include <QWidget>
#include <QGroupBox>
#include <QLabel>
#include <QMap>
#include <QVBoxLayout>

class CameraOneStatusWidget : public QWidget
{
    Q_OBJECT
public:
    explicit CameraOneStatusWidget(const QString& name = "", QWidget *parent = nullptr);
    void setText(const QString& status);
private:
    QLabel* lblStatus;
};

class CameraStatusWidget : public QGroupBox
{
    Q_OBJECT
public:
    explicit CameraStatusWidget(const QString& title = "", QWidget *parent = nullptr);
    void addOne(QString name);
    void removeOne(QString name);
    void setStatus(QString name, QString status);
signals:

private:
    QMap<QString, CameraOneStatusWidget*> mMapWgtCameraStatus;
    QVBoxLayout* mLayout;
};

#endif // CAMERASTATUSWIDGET_H
